﻿<!--
unused
-->
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<%@ taglib uri="/WEB-INF/qa-category.tld" prefix="cat"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<table align="center" border="0" cellpadding="0" cellspacing="0" width="100%">
    <html:form action="/question" method="post" enctype="multipart/form-data">
    <html:hidden property="action" value="add"/>
    <html:hidden property="id"/>
    <tr>
        <td align="right">标题</td>
        <td>
            <html:text property="title" size="50" maxlength="40"/>*(最长40个字符)
            <c:if test="${user_session.type == '1'}">
            &nbsp;&nbsp;<html:checkbox property="isRequireLogin"/>要求登录才能查看
            </c:if>
        </td>
    </tr> 
    <tr>
        <td align="right">内容</td>
        <td>
            <html:textarea property="content" cols="50" rows="10"/>
        </td>
    </tr>
    <tr>
        <td align="right">附件</td>
        <td>
            <html:file property="file" size="50"/>
        </td>
    </tr>
    <tr>
        <td align="right">分类</td>
        <td valign="top">
            <html:select property="cat1Id" multiple="true" size="10">
                <html:option value="">选择分类</html:option>
            </html:select>
            <html:select property="cat2Id" multiple="true" size="10">
                <html:option value="">选择分类</html:option>
            </html:select>
            <html:select property="cat2Id" multiple="true" size="10">
                <html:option value="">选择分类</html:option>
            </html:select>
        </td>
    </tr>
    <tr>
        <td align="right"></td>
        <td>
            <input type="submit" value="提交帖子"/>
        </td>
    </tr>
    </html:form>
</table>
<cat:insert type="D"/>
<script language="Javascript" type="text/javascript">
    function selectedCatChanged(pSelect)
    {
        var index;
        var catId;
        var nextLevel
        var level;
        index = pSelect.selectedIndex;
        level = pSelect.level;
        catId = theSelect.options[index].value;
        var nextLevelCats;
        if(level == 1)
        {
            
            //nextLevelCats = pSelect.form.
        }
    }
    function initSelect()
    {
        var catlistForm = document.getElementById("cats");
        
        
    }
</script>